/*
 * Copyright (c) Huawei Technologies Co., Ltd. 2025. All rights reserved.
 * Description: Hmfs-tools resize main
 */

#include <iostream>

#include "hmfs_command.h"
#include "resize_operator.h"

int main(int argc, char *argv[])
{
    if (argv == nullptr) {
        std::cerr << "Error: argv null" << std::endl;
        return -1;
    }
    OHOS::Hmfs::CmdConfig resizeConfig;
    OHOS::Hmfs::ResizeCmdParser resizeParser(resizeConfig);
    if (resizeParser.Parse(argc, argv) != 0) {
        resizeParser.ShowCmdUsage();
        return -1;
    }
    OHOS::Hmfs::ResizeOperator resizeOperator(resizeConfig);
    return resizeOperator.HmfsResize();
}
